package cn.kgc.springbootday0102.controller;

import cn.kgc.springbootday0102.entity.User;
import cn.kgc.springbootday0102.service.HelloService;
import jakarta.annotation.Resource;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

/**
 * @author 课工场
 * @date 2024/5/24
 * @description
 */
@RestController
@RequestMapping("hello")
public class HelloController {

    @Resource
    private HelloService helloService;


    @RequestMapping("list")
    public List<User> userList(){

      return   helloService.userList();
    }

}
